home *** CD-ROM | disk | FTP | other *** search
/ CU Amiga Super CD-ROM 23 / CU Amiga - Super CD-ROM 23 (June 1998).iso / CreatingGames / Utilities / Basic / BlitzPlay / LookUp < prev    next >
Encoding:
Text File  |  1991-04-22  |  7.8 KB  |  251 lines

  1.  
  2. All registers are saved before these functions do anything out of the
  3. ordinary, but in the event of the CIA replayers, anything could happen.
  4.  
  5. -----------------------------------------------------------------------------
  6.  
  7. Function:        Begin
  8. Syntax:          string$=Begin {NameOfFile$}
  9.  
  10. NameOfFile$ = full path of file to be loaded
  11.  
  12. This routine loads your file, recognises it if possible, does appropriate
  13. relocation and initialization and returns string$, which will contain an
  14. error message if something went wrong, or "" if everything is A.O.K..
  15.  
  16. -----------------------------------------------------------------------------
  17.  
  18. Function:        CreatorID
  19. Syntax:          string$=CreatorID {}
  20.  
  21. This function returns a small ID for the type of module loaded in string$.
  22.  
  23. _ALL_ modules will return something in string$.
  24.  
  25. -----------------------------------------------------------------------------
  26.  
  27. Function:        InitMusic
  28. Syntax:          string$=InitMusic {}
  29.  
  30. This routine performs various initializations on the module.
  31.  
  32. If everything went OK, then "" will be returned in string$, otherwise an
  33. error string will be returned.
  34.  
  35. -----------------------------------------------------------------------------
  36.  
  37. Function:        StartMusic
  38. Syntax:          string$=StartMusic {SongNumber.l}
  39.  
  40. SongNumber.l = Number of SubSong you want to play
  41.  
  42. This routine jumps to the MODs' startmusic routine.
  43.  
  44. Note that before this routine is called, you should use GetNumSongs{} and
  45. SetSongNum{} to play anything bar song #1.
  46.  
  47. If everything is OK, "" is returned in string$, else an error will be given.
  48.  
  49. -----------------------------------------------------------------------------
  50.  
  51. Statement:       StopMusic
  52. Syntax:          StopMusic {}
  53.  
  54. This routine, yep, you guessed it, jumps to the MODs' stopmusic routine.
  55.  
  56. -----------------------------------------------------------------------------
  57.  
  58. Function:        ContinueMusic
  59. Syntax:          byte.b=ContinueMusic {}
  60.  
  61. This function will attempt to continue playing the module where StopMusic
  62. left off and returns True in byte.b for success, False for failure.
  63.  
  64. If the module can't be continued, the routine will call StartMusic{} instead.
  65.  
  66. -----------------------------------------------------------------------------
  67.  
  68. Statement:       EndMusic
  69. Syntax:          EndMusic {}
  70.  
  71. This routine jumps to the MODs' endmusic routine.
  72.  
  73. My brain is straining from RSI.  :)
  74.  
  75. -----------------------------------------------------------------------------
  76.  
  77. Statement:       Finish
  78. Syntax:          Finish {}
  79.  
  80. This routine cleans up all the allocated memory and resets various counters.
  81.  
  82. -----------------------------------------------------------------------------
  83.  
  84. Function:        TimerModes
  85. Syntax:          byte.b=TimerModes {}
  86.  
  87. This routine checks which timing routines are present.
  88.  
  89. It can return byte.b as:
  90. 0 - No timing systems present (Don't ever expect that to happen)
  91. 1 - PAL timing (VBlank50) present
  92. 2 - NTSC timing (VBlank60) present
  93. 4 - TimerTick timing present
  94. If more than one timing system is found the values will be added together.
  95. (seperable with a `byte AND 2' or `byte AND 1' or whatever)
  96.  
  97. -----------------------------------------------------------------------------
  98.  
  99. Function:       Vblank50
  100. Syntax:         byte.b=Vblank50 {}
  101.  
  102. This jumps to the MODs' vblank50 routine and returns True in byte.b.
  103.  
  104. -----------------------------------------------------------------------------
  105.  
  106. Function:       Vblank60
  107. Syntax:         byte.b=Vblank60 {}
  108.  
  109. This jumps to the MODs' vblank60 routine and returns True in byte.b.
  110.  
  111. -----------------------------------------------------------------------------
  112.  
  113. Function:       Channel0
  114. Syntax:         byte.b=Channel0 {}
  115.  
  116. This is for use with GMOD's only, don't ask me _what_ it does :)
  117.  
  118. Returns True for success, False for failure, in byte.b.
  119.  
  120. -----------------------------------------------------------------------------
  121.  
  122. Function:       Channel1
  123. Syntax:         byte.b=Channel1 {}
  124.  
  125. This is for use with GMOD's only, don't ask me _what_ it does :)
  126.  
  127. Returns True for success, False for failure, in byte.b.
  128.  
  129. -----------------------------------------------------------------------------
  130.  
  131. Function:       Channel2
  132. Syntax:         byte.b=Channel2 {}
  133.  
  134. This is for use with GMOD's only, don't ask me _what_ it does :)
  135.  
  136. Returns True for success, False for failure, in byte.b.
  137.  
  138. -----------------------------------------------------------------------------
  139.  
  140. Function:       Channel3
  141. Syntax:         byte.b=Channel3 {}
  142.  
  143. This is for use with GMOD's only, don't ask me _what_ it does :)
  144.  
  145. Returns True for success, False for failure, in byte.b.
  146.  
  147. -----------------------------------------------------------------------------
  148.  
  149. Function:       GetNumSongs
  150. Syntax:         longword.l=GetNumSongs {}
  151.  
  152. Will return the number of songs this module contains in longword.l.
  153.  
  154. -----------------------------------------------------------------------------
  155.  
  156. Statement:      SetSongNum
  157. Syntax:         SetSongNum {SongNumber.l}
  158.  
  159. This routine should be called just before StartMusic{}.
  160.  
  161. Use GetNumSongs{} first to check how many songs there actually are, most
  162. modules will crash if you set a bad number.
  163.  
  164. -----------------------------------------------------------------------------
  165. Function:       GetSongName
  166. Syntax:         string$=GetSongName {}
  167.  
  168. This returns "" in string$ for failure, or the name of the song for success.
  169.  
  170. -----------------------------------------------------------------------------
  171.  
  172. Function:       GetSongAuthor
  173. Syntax:         string$=GetSongAuthor {}
  174.  
  175. This returns "" in string$ for failure, or the name of the author for
  176. success.
  177.  
  178. -----------------------------------------------------------------------------
  179.  
  180. Function:       GetMakerName
  181. Syntax:         string$=GetMakerName {}
  182.  
  183. This returns "" in string$ for failure, or the name of the program that
  184. created the module.
  185.  
  186. -----------------------------------------------------------------------------
  187.  
  188. Function:       GetFrequency
  189. Syntax:         byte.b=GetFrequency {}
  190.  
  191. The value returned is for use with TimerTick, it determines some sort of
  192. value to use to call TimerTick every so often.  To hell with it.  Stick to
  193. CIA and VBlank timing :)
  194.  
  195. -----------------------------------------------------------------------------
  196.  
  197. Function:       TimerTick
  198. Syntax:         byte.b=TimerTick {}
  199.  
  200. Reserved for very weird timing methods, use GetFrequency{} to determine how
  201. often to call this routine.  Better still, stay clear of this altogether :)
  202.  
  203. -----------------------------------------------------------------------------
  204.  
  205. Function:       Hook
  206. Syntax:         longword.l=Hook {HookFlags.l,HookStructureAddress.l}
  207.  
  208. HookFlags.l = Flags for the, erm, hook :)
  209. HookStructureAddress.l = Where the hook is stored in mem
  210.  
  211. Erm, only for use with GMODs I would think, read the GMOD documentation
  212. for more details.
  213.  
  214. -----------------------------------------------------------------------------
  215.  
  216. Function:       Jump
  217. Syntax:         byte.b=Jump {Position.l}
  218.  
  219. Position.l = Position in the module to `jump' to
  220.  
  221. Useful for storing several modules inside the one file, also an alternative
  222. way to use subsongs, mainly in Protracker and MED modules, Jump{} will start
  223. playing the module from the specified Position.l, in the playlist.
  224.  
  225. Returns True for success.
  226.  
  227. -----------------------------------------------------------------------------
  228.  
  229. Function:       SetVolume
  230. Syntax:         byte.b=SetVolume {Left.l,Right.l}
  231.  
  232. Left.l & Right.l = Range should be between 0-255
  233.  
  234. Sets the balance for the left and right channels.  Range from 0-255 for
  235. modules with extremely finetuning (GMODs only so far:)
  236.  
  237. If the moduleplayer routine only handles a mainvolume, the two numbers will
  238. be AVERAGED.
  239.  
  240. Returns True for success.
  241.  
  242. ----------------------------------------------------------------------------
  243.  
  244. Function:       GetScroll
  245. Syntax:         string$=GetScroll {}
  246.  
  247. If the module contains some sort of large info-text, GetScroll{} will return
  248. it in string$.
  249.  
  250. ----------------------------------------------------------------------------
  251.